package com.powernode.config;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 *  白名单数据获取配置对象
 *  @ConfigurationProperties(prefix = "gateway.white")  获取配置文件指定前缀的对应的数据
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@Component
@RefreshScope
@ConfigurationProperties(prefix = "gateway.white")
public class WhithUrlsConfig {

    /**
     * 白名单地址集合
     */
    private List<String> allowUrls;
}
